package com.yeban.javase.day11.test03;

/**
 * @Desc TODO
 * @Author yeban
 * @Date 2025/10/21
 */
public class Book {

    private String type;    // 类型
    private String name;    // 书名
    private Double price;  // 价格


    public Book() {
    }

    public Book(String type, String name, Double price) {
        this.type = type;
        this.name = name;
        this.price = price;
    }

    /**
     * 获取
     * @return type
     */
    public String getType() {
        return type;
    }

    /**
     * 设置
     * @param type
     */
    public void setType(String type) {
        this.type = type;
    }

    /**
     * 获取
     * @return name
     */
    public String getName() {
        return name;
    }

    /**
     * 设置
     * @param name
     */
    public void setName(String name) {
        this.name = name;
    }

    /**
     * 获取
     * @return price
     */
    public Double getPrice() {
        return price;
    }

    /**
     * 设置
     * @param price
     */
    public void setPrice(Double price) {
        this.price = price;
    }

    public String toString() {
        return "Book{type = " + type + ", name = " + name + ", price = " + price + "}";
    }
}
